#include "director.h"


OPEN_JLIB_NS


Director::Director () noexcept {
}

Director::~Director () {
}

void Director::startup (GLView *view, Space *root, const GLView::WindowConfig &config) {
  debug_assert(view && root);
  auto res = view->createWindow(this, config);
  if (!res) {
    log_e("Director: create window failed");
    return;
  }
  _view = view;
  _root = root;

}

void Director::onClose () {
  _flags |= ShouldCloseWindow;
}

void Director::onResize (Vec2i size) {
  _root = 
}

void Director::onResume () {}
void Director::onPause () {}

void Director::onMousePress (MouseEvent::Button code) {}
void Director::onMouseRelease (MouseEvent::Button code) {}
void Director::onMouseMove (Vec2 location) {}
void Director::onMouseEnter () {}
void Director::onMouseLeave () {}
void Director::onMouseScroll (Vec2 offset) {}

void Director::onKeyPress (KeyEvent::Key code) {}
void Director::onKeyRepeat (KeyEvent::Key code) {}
void Director::onKeyRelease (KeyEvent::Key code) {}

void Director::onTouchDown (s32 id, Vec2 location) {}
void Director::onTouchMove (const std::vector<s32>& ids, const std::vector<Vec2>& locations) {}
void Director::onTouchUp (s32 id, Vec2 location) {}
void Director::onTouchCancel (s32 id) {}

void Director::startup (GLView *gl, Vec2 size, Ptr<Space> root) {

}


CLOSE_JLIB_NS
